import React from 'react'

import { PreviewPanel, UploadBar } from '@/components'

import './home.less'

export const Home: React.FC = () => {
  const [previewSrc, setPreviewSrc] = React.useState<string>()
  return (
    <div className="home">
      <PreviewPanel src={previewSrc} />
      <UploadBar
        style={{ marginTop: 16 }}
        onSelect={(src) => {
          setPreviewSrc(src)
        }}
      />
    </div>
  )
}
